package com.example.demo.person.vo;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.util.Date;

/**
 * @author zhangqiang
 * @date 2021/5/29 15:42
 */
@Data
public class PersonVO {

    /**
     * 工号 (不超过8位)
     */
    @ExcelProperty(value = "工号",order = 0)
    private String jobNo;

    /**
     * 姓名 (不超过10个字)
     */
    @ExcelProperty(value = "姓名",order = 1)
    private String name;

    /**
     * 年龄 (18-60)
     */
    @ExcelProperty(value = "年龄",order = 2)
    private Integer age;

    /**
     * 出生年月 (格式yyyy-MM-dd)
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @ExcelIgnore
    private Date birthday;

    /**
     * 国籍
     */
    @ExcelProperty(value = "国籍",order = 3)
    private String nationality;

    /**
     * 婚姻状况 (0-未婚 1-已婚)
     */
    @ExcelIgnore
    private Integer maritalStatus;

    /**
     * 级别 (Primary-初级 Middle-中级 High-高级)
     */
    @ExcelProperty(value = "级别",order = 4)
    private String level;

    /**
     * 自我介绍
     */
    @ExcelProperty(value = "自我介绍",order = 5)
    private String selfIntroduction;

    //-----------------------------extra fields for export excel---------------------------

    @ExcelProperty(value = "出生年月",order = 6)
    private String birthdayStr;

    /**
     * 婚姻状况 (0-未婚 1-已婚)
     */
    @ExcelProperty(value = "婚姻状况",order = 7)
    private String maritalStatusName;

}
